<?php
namespace frontend\controllers;
use yii\web\Controller;
use yii;
class PositionController extends Controller
{
    public function actionPosition()
    {
        $query=Yii::$app->db;
        $command = $query->createCommand('SELECT * FROM jun_position');
        $posts = $command->queryAll();
//        echo "<pre>";
//        print_r($posts);die;
        return $this->renderPartial('position',['posts'=>$posts]);
    }
}